import java.awt.*;
import java.io.*;
import javax.imageio.*;
import javax.swing.*;

public class view extends Component{

	class DrawLine extends JPanel {
    	 
    	public Dimension getPreferredSize() {
    		return new Dimension(600, 600);
    	}
    	 
    	protected void paintComponent(Graphics g) {
    	 
    	g.setColor( Color.black );
    	// Outter Box
    	g.drawRect( 50, 50, 500,520  );
    	// Middle Box
    	g.drawRect(130, 120, 330, 375);
    	// Inner Box
    	g.drawRect(225, 210, 140, 195);
    	//Vertical Lines
    	g.drawLine(300, 50, 300, 210);
    	g.drawLine(300, 405, 300, 570);
    	
    	//Horizontal Lines
    	g.drawLine(50, 310, 225, 310);
    	g.drawLine(365, 310, 550, 310);
    	//g.drawLine (0,0,50,50);
    	}
    }
    private void addComponent(Container container,Component c,int x,int y,int width,int height) {
    	c.setBounds(x,y,width,height);
    	container.add(c);
    }
    public void addImage(){
    	ImageIcon image = new ImageIcon("image.jpeg");
    	
    }
	public void setPVPGameBoard(){
		menu menuSystem = new menu(); 
		JMenuBar menuBar = menuSystem.getMenuBar();
		JPanel panel = new JPanel();
		
		JFrame frame = new JFrame("Nine Men's Morris Player vs Player");
		frame.setVisible(true);
		frame.setSize(800,800);        
        frame.setJMenuBar(menuSystem.getMenuBar());
        addComponent(frame, panel, 0,0,800,800);
       // frame.getContentPane().add();
        panel.add(new DrawLine());

        /*String test1="Matt";
        String test2="Jordan";
        JLabel player1 = new JLabel(test1);
        player1.setHorizontalAlignment(JLabel.LEFT);
        //player1.setVerticalAlignment(JLabel.TOP);
        JLabel label = new JLabel(new ImageIcon("board.jpg"));
        label.setBounds(20,30,16,19);
        panel.add(label);*/
        
        String sPlayerOne = JOptionPane.showInputDialog(null, "Player One's Name", "Enter your name", JOptionPane.QUESTION_MESSAGE);
        String sPlayerTwo = JOptionPane.showInputDialog(null, "Player Two's Name", "Enter your name", JOptionPane.QUESTION_MESSAGE);
               
        
        JLabel jlPlayerOne = new JLabel(sPlayerOne);
        jlPlayerOne.setLocation(100, 100);
        frame.add(panel.add(jlPlayerOne = new JLabel("add JLabel")));
        
        System.out.printf("%s, %s", sPlayerOne, sPlayerTwo);
        	
        

	}
}
